<?php
class PublicAction extends CommonAction {
    public function checkCode() {
        import('Think.Include.CheckCode');
        $checkCode = new CheckCode();
        $checkCode->output();
    }

    public function uploads() {
        $this->display();
    }

    //上传文件
    public function upfile() {
        import('ORG.Util.UploadFile');
        import('ORG.Util.Image');
        $num = $_GET['num'] - 1;
        $up = new UploadFile('myfile', 100000);
        $path = $up->getLinkPath();
        $img = new Image($path);
        $img->thumb(150, 100);
        $img->output(0);           //双图 原图和缩略图
        alertAndCloseOfArr('图片上传成功!', $img->getThumbPath(), $num);
    }


    //浏览器版本过低
    public function remind() {
        $this->display();
    }

}



?>